﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<!--<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE11" />-->
<script src="My97DatePicker/WdatePicker.js"></script>
<script src="public/js/json2.js"></script>

<script language="javascript" for="DPSDK_OCX" event="OnCorrectTalkParamEvent(nTalkType, nAudioType, nAudioBit, nSampleRate, nTransMode)">
	var str = ("Correct Talk Param [nTalkType=" + nTalkType + "]" + " [nAudioType=" + nAudioType + "]" + " [nAudioBit=" + nAudioBit
		+ "]" + " [nSampleRate=" + nSampleRate + "]");
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnMediaDataFirstFrameEvent(szCameraID, nCameraIDLen, nFactoryType, nPlayMode)">
	var str = (" Media Data First Frame [szCameraID=" + szCameraID + "]" + " [nCameraIDLen=" + nCameraIDLen + "]" + " [nFactoryType=" + nFactoryType + "]"
		+ " [nPlayMode=" + nPlayMode + "]");
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnCorrectTalkParamEvent(nTalkType, nAudioType, nAudioBit, nSampleRate, nTransMode)">
	var str = ("Correct Talk Param [nTalkType=]" + nTalkType + " [nAudioType=]" + nAudioType + " [nAudioBit=]" + nAudioBit
		+ " [nSampleRate=]" + nSampleRate + " [nTransMode=]" + nTransMode );
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnDownloadRecordProgress(szFileName,fProgress)">
	document.getElementById("textDownloadProgress").innerText = fProgress;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnDownloadRecordComplete(szFileName)">
	document.getElementById("textDownloadProgress").innerText = 100;
	alert("下载完成!");
</script>

<script language="javascript" for="DPSDK_OCX" event="OnAlarmEvent(szAlarmId, szCameraId, szDeviceName, szChannelName, nAlarmType, nEventType, nLevel, nTime)">
    
	var str = ("OnAlarmEvent [szAlarmId=]" + szAlarmId + " [szCameraId=]" + szCameraId + "[szDeviceName=]" + szDeviceName
		+ "[szChannelName=]" + szChannelName + "[nAlarmType=]" + nAlarmType + "[nEventType=]" + nEventType + "[nLevel=]" + nLevel + "[nTime=]" + nTime);
	document.getElementById("GlobalInfo").innerText = str;
		
	if(8 == nAlarmType)
	{
		//alert(szChannelName);
	}
	else if((300 < nAlarmType)&&(nAlarmType < 1100))
	{
		//alert(szChannelName);
	}
	else
	{
		//alert(szCameraId);
	}
</script>

<script language="javascript" for="DPSDK_OCX" event="OnDevStatusEvent(szDevId, nStatus)">
	var str = "";    
	switch(nStatus)
	{
		case 1:
			//alert("设备上线！" + szDevId);
			str = "设备上线！" + szDevId;
            //ButtonGetDGroupInfo_onclick();
            ButtonStartRealplayByWndNo_onclick();
            //ButtonStartRealplayByWndNo_onclickSelect();
			break;
		case 2:
			//alert("设备离线！" + szDevId);
			str = "设备离线！" + szDevId;
			break;			
	}
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnNvrChannelStatusEvent(szChnlId, nStatus)">
	var str = "";    
	switch(nStatus)
	{
		case 1:
			str = "通道上线！" + szChnlId;
			break;
		case 2:
			str = "通道离线！" + szChnlId;
			break;			
	}
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnGeneralJsonCallBack(Json)">
	var str1 = "json返回结果：";
	var str = str1 + Json;
	document.getElementById("JsonResult").innerText = str;
	
	var jsonObj = JSON.parse(Json);
	var strMethod = jsonObj.method;
	
	if (strMethod == "cu.searchSnapPicUrl") {
		var obj = document.getElementById("DPSDK_OCX");
		var ftpInfo = obj.DPSDK_GetFTPInfo();
		var picurl = jsonObj.params.snapPicList[0].snapPicUrl;
		var ftpurl = ftpInfo + picurl;
		alert(ftpurl);
		document.getElementById("snapPicture").src = ftpurl;
	}
	else if (strMethod == "dms.getSnapPic") {
		var picdata = jsonObj.params.PicData;
		alert(picdata);
	}
	else if (strMethod == "Scs.NotifyBye")
	{
		alert("通话结束");
	}
</script>

<script language="javascript" for="DPSDK_OCX" event="OnServerStatusChangeEvent(nStatus)">
	var str = "";    
	switch(nStatus)
	{
		case 1:
			str = "服务上线！";
			var obj = document.getElementById("DPSDK_OCX");
			ShowCallRetInfo(obj.DPSDK_LoadDGroupInfo(), "加载组织结构");
			break;
		case 2:
			str = "服务离线！";
			break;			
	}
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnAsyncLoadDGroupInfoComplete(nRet, nGroupLen)">
	var str = ("AsyncLoadDGroupInfoComplete [nRet=]" + nRet + " [nGroupLen=]" + nGroupLen);
	document.getElementById("RetInfo").innerText = str;
	var obj = document.getElementById("DPSDK_OCX");
//	document.getElementById("DGroupInfo").innerText = obj.DPSDK_GetDGroupStr();
</script>

<script language="javascript" for="DPSDK_OCX" event="OnWndLBtnClick(nWndId, nWndNo, xPos, yPos)">
	var str = ("OnWndLBtnClick [nWndId=]" + nWndId + " [nWndNo=]" + nWndNo + " [xPos=]" + xPos + " [yPos=]" + yPos);
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnWndRBtnClick(nWndId, nWndNo, xPos, yPos)">
	var str = ("OnWndRBtnClick [nWndId=]" + nWndId + " [nWndNo=]" + nWndNo + " [xPos=]" + xPos + " [yPos=]" + yPos);
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnDoorStatusReportEvent(szCameraId, status, time)">
	var doorstatus = "";    
	switch(status)
	{
		case 1:
			doorstatus = "开门！";
			break;
		case 0:
			doorstatus = "关门！";
			break;
		case 2:
			doorstatus = "离线！";
			break;
	}
	var str = ("DoorStatusReport [szCameraId=]" + szCameraId + " [status=]" + doorstatus + " [time=]" + time);
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnNetAlarmHostStatusReportEvent(szDeviceId, nReportType, nOperationType, nStatus)">
	var strReportType = "";
	var strOperationType = "";
	var strStatus = "";
	switch(nReportType)
	{
		case 1:
			strReportType = "留守布防";
			break;
		case 2:
			strReportType = "防区旁路";
			break;
		default:
			strReportType = "未知";
			break;
	}
	switch(nOperationType)
	{
		case 1:
			strOperationType = "设备 布/撤防";
			break;
		case 2:
			strOperationType = "通道 布/撤防";
			break;
		case 3:
			strOperationType = "报警输出通道操作";
			break;
		default:
			strOperationType = "未知";
			break;
	}
	switch(nStatus)
	{
		case 1:
			strStatus = "布防/旁路";
			break;
		case 2:
			strStatus = "撤防/取消旁路";
			break;
		default:
			strStatus = "未知";
			break;
	}
	var str = ("网络报警主机状态上报 [szCameraId=]" + szDeviceId + " [ReportType=]" + strReportType + " [OperationType=]" + strOperationType + " [Status=]" + strStatus);
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnVideoAlarmHostStatusReportEvent(szDeviceId, nChannelNO, nStatus)">
	var strStatus = "";
	switch(nStatus)
	{
		case 1:
			strStatus = "针对设备布防";
			break;
		case 3:
			strStatus = "针对设备撤防";
			break;
		case 4:
			strStatus = "针对通道旁路";
			break;
		case 5:
			strStatus = "针对通道取消旁路";
			break;
		case 6:
			strStatus = "针对设备在家布防";
			break;
		case 7:
			strStatus = "针对设备外出布防";
			break;
		default:
			strStatus = "未知";
			break;
	}
	var str = ("视频报警主机状态上报 [szCameraId=]" + szDeviceId + " [ChannelNO=]" + nChannelNO + " [Status=]" + strStatus);
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnBayCarInfoEvent(szBayCarInfo)">
    
	document.getElementById("GlobalInfo").innerText = szBayCarInfo;
	alert(szBayCarInfo);
	
</script>

<script language="javascript" for="DPSDK_OCX" event="OnChannelViewInfoReportEvent(szCamearId, nDistance, nAngelH, nAzimuthH, nInclinationH)">
    
	var str = ("OnChannelViewInfoReportEvent [szCamearId=]" + szCamearId + " [nDistance=]" + nDistance + "[nAngelH=]" + nAngelH
		+ "[nAzimuthH=]" + nAzimuthH + "[nInclinationH=]" + nInclinationH );
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnAsyncLoginComplete(nRet)">
	if(nRet == 0)
	{
		bLogin = 1;
	}
	ShowCallRetInfo(nRet, "异步登录");
</script>

<script language="javascript" for="DPSDK_OCX" event="OnAsyncStartRealplayComplete(nRet, nWndId, nWndNo)">
	var str; 
	if(nRet == 0)
	{
		str = "异步播放视频成功，nWndId = " + nWndId + "，nWndNo = " + nWndNo;
		var szCameraId = document.getElementById("textCameraID").value;
		var obj = document.getElementById("DPSDK_OCX");
		var nWndNo = obj.DPSDK_GetSelWnd(gWndId);
		insertRealplayHistory(szCameraId);
		ShowCallRetInfo(obj.DPSDK_SetIvsShowFlagByWndNo(gWndId, nWndNo, 1, bIVS),"规则线显示");//打开规则线显示
		ShowCallRetInfo(obj.DPSDK_SetIvsShowFlagByWndNo(gWndId, nWndNo, 2, bIVS),"目标框显示");//打开目标框显示
		ShowCallRetInfo(obj.DPSDK_SetIvsShowFlagByWndNo(gWndId, nWndNo, 3, bIVS),"轨迹线显示");//打开轨迹线显示
	}
	else
	{
		str = "异步播放视频失败，错误码：" + nRet;
	}
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnAsyncStopRealplayComplete(nRet, nWndId, nWndNo)">
	var str; 
	if(nRet == 0)
	{
		str = "异步停止视频成功，nWndId = " + nWndId + "，nWndNo = " + nWndNo;
	}
	else
	{
		str = "异步停止视频失败，错误码：" + nRet;
	}
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnAsyncPtzDirectionComplete(nRet, szCameraId)">
	var str; 
	if(nRet == 0)
	{
		str = "异步云台方向控制成功，szCameraId = " + szCameraId;
	}
	else
	{
		str = "异步云台方向控制失败，错误码：" + nRet;
	}
	document.getElementById("GlobalInfo").innerText = str;
</script>

<script language="javascript" for="DPSDK_OCX" event="OnVtCallInviteCallback(szUserId)">
	var str = szUserId + "请求可视对讲";
	alert(str);
</script>

<script language="javascript" for="DPSDK_OCX" event="OnBusyVtCallCallback()">
	var str = "呼叫繁忙";
	document.getElementById("GlobalInfo").innerText = str;
</script>

<title>测试视频</title>
<link rel="stylesheet" type="text/css" href="public/css/DSSPlay.css"/>
	   <style type="text/css">
		   #monitoringChannelId option{
			   line-height: 30px;
		   }
	   </style>
<script src="public/js/ocxfun_new.js"></script>
	   <!--xml格式的组织结构转json获取-->
	   <script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.js"></script>
	   <script type="text/javascript" src="http://www.jsons.cn/Down/jquery.xml2json.js"></script>
</head>
<body id="mbody" onload="init();"  onunload="ButtonLogout_onclick()">
<div id="mainbg">
<div id="main">
	    <div style="width: 90%;height: 30px;overflow: auto;" id="RetInfo">
			
		</div>
		<div style="width: 90%;height: 30px;overflow: auto;" id="GlobalInfo">
			
		</div>
										
		 <div class="box_top"></div>
		<div id="mviewl">
			<div id="obj">
				<object id="DPSDK_OCX" classid="CLSID:D3E383B6-765D-448D-9476-DFD8B499926D" style="width: 100%; height: 80%" codebase="DpsdkOcx.cab#version=1.0.0.0"></object>
			</div>
			
		</div>
		 <!--<div class="box_bottom">
          <div class="box_bottom_btn">
           		<ul>
           			<li id="back_btn_li"><a class="back_btn"  href="javascript:back();" onmousedown="mousedown(this)" onmouseup="mouseup(this)" ></a></li>
           			<li><a class="play_btn" href="javascript:stop();" onmousedown="mousedown(this)" onmouseup="mouseup(this)"></a></li>
           			<li><a class="stop_btn" href="javascript:play();" onmousedown="mousedown(this)" onmouseup="mouseup(this)"></a></li>
           			<li><a class="go_btn" href="javascript:go();" onmousedown="mousedown(this)" onmouseup="mouseup(this)"></a></li>
           			<li><a class="photo_btn" href="javascript:photo();" onmousedown="mousedown(this)" onmouseup="mouseup(this)"></a></li>
           		</ul>
           </div>

	
	
	<div class="box_bottom_a"><a href='DSSClientOCX.exe'>点击这里手动下载最新的控件</a></div>
</div>-->
</div>
<div class="rightDiv" style="width:50%">
	<div style="border:1px solid white;padding-top:5px;">
    	通道ID：<!--<input type="text" id="textCameraID" value="1000002$1$0$0" />-->
		<select id="monitoringChannelId" onchange="ButtonStartRealplayByWndNo_onclickSelect()" style="height: 30px;line-height: 30px; width: 210px;">
			<option value="1000002$1$0$1">1000002$1$0$1</option>
			<!--<option value="1000002$1$0$2">1000002$1$0$2</option>
			<option value="1000002$1$0$3">1000002$1$0$3</option>
			<option value="1000002$1$0$4">1000002$1$0$4</option>-->
		</select>
		设置窗口数量：
		<input type="text" id="textWndNum" value="4" size=""/>
		<input type="button" id="buttonCreateWnd" value="设置" class="button" onclick="return ButtonCreateWnd_onclick()" />
		<input type="button" id="buttonLogout" value="登出" class="button" onclick="return ButtonLogout_onclick()" />
	</div>
	<!--<ul id="tab">
	<li class="on" id="tab_1" >登录</li>
	<li class="" id="tab_2" >实时</li>
	</ul>-->
	<ul id="tab_con">
	<li id="tab_con_1">
	<div style="padding-top:20px; display: none">
		<div style="margin-left: 10px;">
			设置窗口数量：
			<!--<input type="text" id="textWndNum" value="1" size="5"/>
			<input type="button" id="buttonCreateWnd" value="设置" class="button" onclick="return ButtonCreateWnd_onclick()" />&nbsp;
			设置定制化窗口数量：
			<input type="text" id="textWndNum2" value="4" size="5"/>
			<input type="button" id="buttonSetCustomizedWndCount" value="设置" class="button" onclick="return ButtonSetCustomizedWndCount_onclick()" />-->
		</div>
		<div style="margin-left: 10px;">
			<input type="text" id="WndText" value="通道——1" size="10"/>
			<input type="button" id="buttonSetWndText" value="窗口显示文字" class="button" onclick="return ButtonSetWndText_onclick()" />
			<input type="button" id="buttonSetSmartWndFullScreen" value="全屏显示Smart窗口" class="button" onclick="return ButtonSetSmartWndFullScreen_onclick()" />
			<input type="button" id="buttonSetWndFullScreen" value="全屏显示选中窗口" class="button" onclick="return ButtonSetWndFullScreen_onclick()" />
			<input type="button" id="buttonOpenTime" value="打开全网校时" class="button" onclick="return ButtonOpenTime_onclick()" />
			&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
			<select id="selectWndStyle" >
				<option value="0">普通风格</option>
				<option value="1">定制风格</option>
				<option value="2">播放视频失败窗口变灰</option>
			</select>
			<input type="button" id="buttonSetWndStyle" value="设置窗口风格" class="button" onclick="return ButtonSetWndStyle_onclick()" />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
			<input type="button" id="buttonSubscribeAllBayCarInfo" value="订阅所有卡口过车数据" class="button" onclick="return ButtonSubscribeAllBayCarInfo_onclick()" />
			<input type="button" id="buttonUndoSubscribe" value="取消订阅" class="button" onclick="return ButtonUndoSubscribe_onclick()" />
			<select id="selectVideoPlayInfo" >
				<option value="true">显示</option>
				<option value="false">不显示</option>
			</select>
			<input type="button" id="buttonShowVideoPlayInfo" value="设置显示视频播放信息" class="button" onclick="return ButtonShowVideoPlayInfo_onclick()" />
		</div>
	</div>
	<div style="">
		<div style="width:50%; float:left;display: none">
			登陆登出
			IP<input type="text" id="textIP" value="58.58.232.70"  size="10"/>
			端口：<input type="text" id="textPort" value="9000" size="10"/>
			用户名<input type="text" id="textUser" value="admin" size="10"/>
			密码：<input type="text" id="textPassword" value="admin" size="10"/>
			
			<input type="button" id="buttonLogin" value="登录" class="button" onclick="return ButtonLogin_onclick()" />
			<input type="button" id="buttonAsyncLogin" value="异步登录" class="button" onclick="return ButtonAsyncLogin_onclick()" />
			<!--<input type="button" id="buttonLogout" value="登出" class="button" onclick="return ButtonLogout_onclick()" />-->
			<input type="button" id="buttonLoadDGroupInfo" value="加载组织结构" class="button" onclick="return ButtonLoadDGroupInfo_onclick()" />
			<input type="button" id="buttonAsyncLoadDGroupInfo" value="异步加载组织结构" class="button" onclick="return ButtonAsyncLoadDGroupInfo_onclick()" />
			<input type="button" id="buttonGetDGroupInfo" value="获取组织结构" class="button" onclick="return ButtonGetDGroupInfo_onclick()" />
			<input type="button" id="buttonConnectDmsByChnlId" value="根据通道ID连接DMS" class="button" onclick="return ButtonConnectDmsByChnlId_onclick()" />
		</div>
		<div style="width: 50%;height: 150px;overflow: auto; float: left; display: none" id="DGroupInfo"></div>
		<div style="clear:both"></div>
	</div>
	<div style="border:1px solid white;padding:5px;display: none">
		<input type="button" id="logPathName" value="设置log文件" onclick="return SetLog()" />
		type：  &nbsp;&nbsp; <input type="text" id="textType" value="0" size="2"/>
		mode：  &nbsp;&nbsp; <input type="text" id="textMode" value="0" size="2"/>
		<input type="button" id="setTypeMode" value="设置显示模式" onclick="return SetControlButtonShowMode()" />
		<input type="button" id="getGPS" value="获取经纬度" onclick="return GetGps()" />&nbsp;&nbsp;&nbsp;&nbsp;
		<input type="button" id="StartMonitor" value="开启崩溃自动生成dump" onclick="return StartMonitor()" />
		<input type="button" id="StopMonitor" value="关闭崩溃自动生成dump" onclick="return StopMonitor()" />
	</div>
	<div style="border:1px solid white;padding:5px; display: none">
		前端摄像机抓拍</br>
		设备ID：&nbsp;<input type="text" id="DevID" value="1000726" size="8" />&nbsp;&nbsp;
		通道号：&nbsp;<input type="text" id="ChannelNo" value="0" size="2" />&nbsp;&nbsp;
		抓拍间隔(秒)：<input type="text" id="Interval" value="10" size="3.5" /> &nbsp;&nbsp;
		请求ID号：&nbsp;<input type="text" id="jsonID" value="88" size="4" /> &nbsp;&nbsp;
		<input type="button" id="buttonSetSnapshotInterval" value="设置抓图间隔" class="button" onclick="return ButtonSetSnapshotInterval_onclick()" /> </br>
		设备ID：&nbsp;<input type="text" id="SnapDevID" value="1000726" size="8" />&nbsp;&nbsp;
		通道号：&nbsp;<input type="text" id="SnapChannelNo" value="0" size="2" />&nbsp;&nbsp;
		图片类型：&nbsp;<select id="SnapType" ><option value="2">返回图片数据</option><option value="1">返回图片地址</option></select> &nbsp;
		请求ID号：&nbsp;<input type="text" id="SnapjsonID" value="90" size="2" />&nbsp;&nbsp;
		<input type="button" id="buttonSnap" value="前端设备抓图" class="button" onclick="return ButtonSnap_onclick()" />
	</div>
	
	<div style="padding:5px; display: none">
		江苏海事局长江航道项目定制</br>
		设备ID：&nbsp;<input type="text" id="AngleDevID" value="1000021" size="8" />&nbsp;&nbsp;
		通道号：&nbsp;<input type="text" id="AngleChannelNo" value="0" size="2" />&nbsp;&nbsp;
		水平角(0-3600)：&nbsp;<input type="text" id="AngleX" value="900" size="2" />&nbsp;&nbsp;
		垂直角(-1800-1800)：&nbsp;<input type="text" id="AngleY" value="0" size="2" />&nbsp;&nbsp;
		请求ID号：&nbsp;<input type="text" id="AnglejsonID" value="91" size="2" />&nbsp;&nbsp;
		<input type="button" id="buttonSnap" value="设置球机转动角度" class="button" onclick="return ButtonSetCameraAngle_onclick()" /> </br>
		设备ID：&nbsp;<input type="text" id="ScaleDevID" value="1000021" size="8" />&nbsp;&nbsp;
		通道号：&nbsp;<input type="text" id="ScaleChannelNo" value="0" size="2" />&nbsp;&nbsp;
		物体距离(cm)：&nbsp;<input type="text" id="nDistance" value="1200" size="2" />
		物体宽度(cm)：&nbsp;<input type="text" id="nWidth" value="500" size="2" />
		物体占屏比(cm)：&nbsp;<input type="text" id="nScreenRatio" value="200" size="2" />
		请求ID号：&nbsp;<input type="text" id="ScreenRatiojsonID" value="92" size="1" />
		<input type="button" id="buttonSnap" value="设置船只占屏比" class="button" onclick="return ButtonObiectScreenRatio_onclick()" />
	</div>
	<div style="padding:5px;display: none">
		通用json发送</br>
		json字符串：&nbsp;<input type="text" id="Generaljson"  size="30" /> &nbsp;&nbsp;&nbsp;&nbsp;
		要发往的服务：<select id="selectMdl" >
				<option value="0">APP模块</option>
				<option value="1">CMS模块</option>
				<option value="2">PCS模块</option>
				<option value="3">DMS模块</option>
				<option value="4">ADS模块</option>
				<option value="5">TRAN模块</option>
				<option value="6">RTSP模块</option>
				<option value="7">FTP模块</option>
				<option value="8">PEC模块</option>
				<option value="9">MGR模块</option>
				<option value="10">AREA模块</option>
				<option value="11">FORSNVD模块</option>
				<option value="12">SCS模块</option>
			</select>&nbsp;&nbsp;&nbsp;&nbsp;
		传输类型：<select id="selectTransportType" >
				<option value="0">请求</option>
				<option value="1">回复</option>
				<option value="2">通知</option>
			</select>
			</br>
		<input type="button" id="ButtonSendGeneraljson" value="发送通用json" class="button" onclick="return ButtonSendGeneraljson_onclick()" />
		</br>
		<select id="selectSubscribeAllBayCarInfo" >
				<option value="1">订阅过车流量</option>
				<option value="0">取消订阅过车流量</option>
		</select>
		<input type="button" id="ButtonSubscribeAllBayCarInfo" value="过车流量" class="button" onclick="return ButtonSubscribeAllBayCarInfo_onclick()" />
		</br>
		通道名称：&nbsp;<input type="text" id="ChnlName"  size="30" />
		<input type="button" id="ButtonGetChnlID" value="获取通道ID" class="button" onclick="return ButtonGetChnlID_onclick()" />
		设备ID：&nbsp;<input type="text" id="QueryNVRDevId"  size="30" />
		<input type="button" id="ButtonQueryNVRChnlStatus" value="查询NVR通道状态" class="button" onclick="return ButtonQueryNVRChnlStatus_onclick()" />
		</br>
		<div style="border:1px solid white;padding:5px;">
			贵阳防汛决策平台项目定制</br>
			通道ID： <input type="text" id="ChnlID" value="1000008$1$0$0" size="30" />
			开始时间：<input id="searchStartTime" type="text" name="" value='2017-03-31 00:00:00' onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',startDate:'%y-%M-%d 00:00:00',maxDate:'%y-%M-%d',minDate:'1970-01-01 10:00:00'})" class="select-text" style="padding: 0 5px;" readonly/>
			结束时间：<input id="searchEndTime" type="text" name="" value='2017-03-31 11:59:59' onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',minDate:'1970-01-01 10:00:00'})" class="select-text" style="padding: 0 5px;" readonly/>
			<br />
			<input type="button" id="ButtonSearchPicture" value="查询图片" class="button" onclick="return ButtonSearchPicture_onclick()" />
			<br />
			<input type="text" id="PictureFtpUrl" size="30" />
			<input type="button" id="ButtonGetPictureData" value="获取图片数据" class="button" onclick="return ButtonGetPictureData_onclick()" />
			<br />
			<img id="snapPicture" src="" />
		</div>
		
	</div>
	<div style="padding:5px;display: none">
		人数统计</br>
		开始时间：<input id="textPersonCountStartTime" type="text" name="" value='2018-10-19 00:00:00' onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',startDate:'%y-%M-%d 00:00:00',maxDate:'%y-%M-%d',minDate:'1970-01-01 10:00:00'})" class="select-text" style="padding: 0 5px;" readonly/>
		结束时间：<input id="textPersonCountEndTime" type="text" name="" value='2018-10-19 23:59:59' onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',minDate:'1970-01-01 10:00:00'})" class="select-text" style="padding: 0 5px;" readonly/>
		查询粒度：<select id="selecGranularity" >
				<option value="0">分钟</option>
				<option value="1">小时</option>
				<option value="2" selected = "selected">日</option>
				<option value="3">周</option>
				<option value="4">月</option>
				<option value="5">季</option>
				<option value="6">年</option>
			</select></br>
		<input type="button" id="ButtonQueryPersonCount" value="查询人数统计" class="button" onclick="return ButtonQueryPersonCount_onclick()" /><br />
	</div>
	</li>
	<li id = "tab_con_2">
	<div style="padding-top:20px; display: none">
		<div style="margin-left: 10px;">
			实时视频</br>
			<select id="selectStreamType" >
				<option value="1">主码流</option>
				<option value="2">辅码流</option>
			</select>
			<select id="selectMediaType" >
				<option value="1">视频</option>
				<option value="2">音频</option>
				<option value="3">视频 + 音频</option>
			</select>
			<select id="selectTransType" >
				<option value="1">TCP</option>
				<option value="0">UDP</option>
			</select>
			</br> ftp信息</br>
			ftp IP：<input type="text" id="textFtpIp" value="58.58.232.70" size="10" /> </br>
			username :<input type="text" id="textFtpName" value="admin" size="10" /> </br>
			password :<input type="text" id="textFtpPwd" value="admin" size="10" /> &nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
			<input type="button" id="buttonIVSSwitchByWndNo" value="按窗口号开关智能线" onclick="return ButtonIVSSwitchByWndNo_onclick()" />
			<input type="button" id="buttonGetExtrenUrl" value="获取外部URL" onclick="return buttonGetExtrenUrl_onclick()" />
			<div style="border:1px solid white;padding:5px;">
			按窗口号
			<input type="button" id="buttonStartRealplayByWndNo" value="播放视频" onclick="return ButtonStartRealplayByWndNo_onclick()" />
			<input type="button" id="buttonAsyncStartRealplayByWndNo" value="异步播放视频" onclick="return ButtonAsyncStartRealplayByWndNo_onclick()" />
			<input type="button" id="buttonStopRealplayByWndNo" value="关闭视频" onclick="return ButtonStopRealplayByWndNo_onclick()" />
			<input type="button" id="buttonAsyncStopRealplayByWndNo" value="异步关闭视频" onclick="return ButtonAsyncStopRealplayByWndNo_onclick()" />
			<input type="button" id="buttonCapturePictureByWndNo" value="抓图" onclick="return ButtonCapturePictureByWndNo_onclick()" />
			<input type="button" id="buttonCapturePictureByWndNoAndUpload" value="抓图并上传至ftp" onclick="return ButtonCapturePictureByWndNoAndUpload_onclick()" />	
			<input type="button" id="buttonStartRealRecordByWndNo" value="开始录像" onclick="return ButtonStartRealRecordByWndNo_onclick()" />
			<input type="button" id="buttonStartAVIRealRecordByWndNo" value="开始AVI格式录像" onclick="return ButtonStartAVIRealRecordByWndNo_onclick()" />
			<input type="button" id="buttonStopRealRecordByWndNo" value="停止录像" onclick="return ButtonStopRealRecordByWndNo_onclick()" />
			<input type="button" id="buttonOpenAudioByWndNo" value="打开音频" onclick="return ButtonOpenAudioByWndNo_onclick()" />
			<input type="button" id="buttonCloseAudioByWndNo" value="关闭音频" onclick="return ButtonCloseAudioByWndNo_onclick()" />
			</div>
			<div style="border:1px solid white;padding:5px;display: none">
			按窗口句柄
			<input type="button" id="buttonStartRealplayByHWND" value="播放视频" onclick="return ButtonStartRealplayByHWND_onclick()" />
			<input type="button" id="buttonStopRealplayByHWND" value="关闭视频" onclick="return ButtonStopRealplayByHWND_onclick()" />
			<input type="button" id="buttonCapturePictureByHWND" value="抓图" onclick="return ButtonCapturePictureByHWND_onclick()" />
			<input type="button" id="buttonCapturePictureByHWNDAndUpload" value="柄抓图并上传至ftp" onclick="return ButtonCapturePictureByHWNDAndUpload_onclick()" />
			<input type="button" id="buttonStartRealRecordByHWND" value="开始录像" onclick="return ButtonStartRealRecordByHWND_onclick()" />
			<input type="button" id="buttonStopRealRecordByHWND" value="停止录像" onclick="return ButtonStopRealRecordByHWND_onclick()" />
			<input type="button" id="buttonOpenAudioByHWND" value="打开音频" onclick="return ButtonOpenAudioByHWND_onclick()" />
			<input type="button" id="buttonCloseAudioByHWND" value="关闭音频" onclick="return ButtonCloseAudioByHWND_onclick()" />
			</div>
		</div>
		<div style="border:1px solid white;padding:5px; display: none">
		音频通道数：<input type="text" id="textAudioNum" value="0" size="5" />
		音频通道号：<input type="text" id="textAudioIndex" value="0" size="5" /> 
		音频状态：<input type="text" id="textAudioState" value="0" size="5" /> </br>
			<div style="border:1px solid white;padding:5px;">
			按窗口号
				<input type="button" id="buttonGetAudioChannelsByWndNo" value="获取音频通道数量" onclick="return ButtonGetAudioChannelsByWndNo_onclick()" />
				<input type="button" id="buttonGetAudioChannelStateByWndNo" value="获取通道状态" onclick="return ButtonGetAudioChannelStateByWndNo_onclick()" />
				<input type="button" id="buttonSetAudioChannelByWndNo" value="设置通道状态" onclick="return ButtonSetAudioChannelByWndNo_onclick()" />
			</div>
			<div style="border:1px solid white;padding:5px;">
			按窗口句柄
				<input type="button" id="buttonGetAudioChannelsByHWND" value="获取音频通道数量" onclick="return ButtonGetAudioChannelsByHWND_onclick()" />
				<input type="button" id="buttonGetAudioChannelStateByHWND" value="获取通道状态" onclick="return ButtonGetAudioChannelStateByHWND_onclick()" />
				<input type="button" id="buttonSetAudioChannelByHWND" value="设置通道状态" onclick="return ButtonSetAudioChannelByHWND_onclick()" />
			</div>
		</div>
		<div style="border:1px solid white;padding:5px;display: none">
		Osd信息：<input type="text" id="textOsd" value="渔船|2016-12-22 10:30:00|出港" size="40" /> </br>
		<div style="border:1px solid white;padding:5px;">
		按窗口号
			<input type="button" id="buttonSetOsdTxtByWndNo" value="设置本地窗口Osd信息" onclick="return ButtonSetOsdTxtByWndNo_onclick()" />
			<input type="button" id="buttonCleanUpOsdInfoByWndNo" value="清除本地窗口Osd信息" onclick="return ButtonCleanUpOsdInfoByWndNo_onclick()" />
			<input type="button" id="buttonSetOsdTxt" value="设置摄像头码流Osd信息" onclick="return ButtonSetOsdTxt_onclick()" />
			<input type="button" id="buttonCleanOsdTxt" value="清除摄像头码流Osd信息" onclick="return ButtonCleanOsdTxt_onclick()" /></br>
		</div>
		<div style="border:1px solid white;padding:5px;">
		按窗口句柄
			<input type="button" id="buttonSetOsdTxtByHWND" value="设置本地窗口Osd信息" onclick="return ButtonSetOsdTxtByHWND_onclick()" />
			<input type="button" id="buttonCleanUpOsdInfoByHWND" value="清除本地窗口Osd信息" onclick="return ButtonCleanUpOsdInfoByHWND_onclick()" /></br>
		</div>
		</div>
		<div style="border:1px solid white;padding:5px;display: none">
		亮度：<input type="text" id="textBrightness" value="64" size="5" />
		对比度：<input type="text" id="textContract" value="64" size="5" />
		饱和度：<input type="text" id="textSaturation" value="64" size="5" />
		色调：<input type="text" id="textTone" value="64" size="5" /> </br>
			<div style="border:1px solid white;padding:5px;">
			按窗口号
				<input type="button" id="buttonAdjustColorByWndNo" value="屏幕颜色调整" onclick="return ButtonAdjustColorByWndNo_onclick()" />
			</div>
			<div style="border:1px solid white;padding:5px;">
			按窗口句柄
				<input type="button" id="buttonAdjustColorByHWND" value="屏幕颜色调整" onclick="return ButtonAdjustColorByHWND_onclick()" />
			</div>
		</div>
		<!-- <div style="margin-left: 10px; margin-top: 10px;">
			<input type="button" id="buttonGetAudioChannelsByHWND" value="DPSDK_GetAudioChannelsByHWND" onclick="return ButtonGetAudioChannelsByHWND_onclick()" />
			<input type="button" id="buttonGetAudioChannelStateByHWND" value="DPSDK_GetAudioChannelStateByHWND" onclick="return ButtonGetAudioChannelStateByHWND_onclick()" />
			<input type="button" id="buttonSetAudioChannelByHWND" value="DPSDK_SetAudioChannelByHWND" onclick="return ButtonSetAudioChannelByHWND_onclick()" /></br></br>
		</div> -->
		<div style="border:1px solid white;padding:5px;display: none">
		IP:<input type="text" id="textJDIP" value="" size="8" />
		端口：<input type="text" id="textJDPort" value="" size="5" />
		硬盘录像机编码：<input type="text" id="textJDDvrCode" value="" size="5" />
		访问令牌：<input type="text" id="textJDToken" value="" size="5" />
		<input type="button" id="buttonCheckRealPlayAuth" value="在线视频播放鉴权" onclick="return ButtonCheckRealPlayAuth_onclick()" />
		</div>
		<div style="border:1px solid white;padding:5px;display: none">
		<input type="button" id="buttonStopAllPlay" value="停止所有预览" onclick="return ButtonStopAllPlay_onclick()" />
		<input type="button" id="buttonGetFirstFreeWindow" value="获取空闲窗口" onclick="return ButtonGetFirstFreeWindow_onclick()" />
		<input type="button" id="buttonStartRealplayByFreeWnd" value="空闲窗口预览" onclick="return ButtonStartRealplayByFreeWnd_onclick()" />
		<input type="button" id="buttonGetPlayCameraIdByWndNo" value="获取播放窗口通道ID" onclick="return ButtonGetPlayCameraIdByWndNo_onclick()" />
		</div>
	</div>
	</li>
	</ul>
	<div style="width: 90%;height: 60px;overflow: auto;" id="JsonResult">		
	</div>
	<table id="realplayHistory" style="display: none">
		<thead>
			<tr>
				<th>历史通道ID</th>	
			</tr>
		</thead>
		<tbody id="historyContent">
			<tr style="" id="historySample">
				<td class="cameraId"></td>
				<td><button>播放</button></td>
			</tr>
		</tbody>
	</table>
</div>
</div>
<script type="text/javascript">
    $(document).ready(function(){
        window.onunload = function(event) {
            return ButtonLogout_onclick();
        }
    });
</script>
</body>
</html>